package com.mdd.front.controller;

import com.mdd.common.core.AjaxResult;
import com.mdd.common.core.PageResult;
import com.mdd.front.service.account.IAccountLogService;
import com.mdd.front.validate.PageParam;
import com.mdd.front.vo.account.AccountLogListVo;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;

import javax.annotation.Resource;
import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/api/account/log")
public class AccountLogController {

    @Resource
    private IAccountLogService iAccountLogService;

    @GetMapping("/list")
    public AjaxResult list(@Validated PageParam pageParam,
                           @RequestParam Map<String, String> params){
        PageResult<AccountLogListVo> list = iAccountLogService.list(pageParam, params);
        return AjaxResult.success(list);
    }
}
